Showing posts with label table. Show all posts
Showing posts with label table. Show all posts

Saturday, March 31, 2012

Submitting Form to Database

I have an ASP.Net page created with a table I made to look like a form
for our benefit request program. How do I code this properly to send
it to a table in our database.

For the sake of me learning how to do this lets just do short example
like. I have an aspx page with a label for name and a text box where
a user can input their name.

I have a database table called tblName with a column called name where
the submitted names go.

How do I code it so the name is submitted, a confirmation page is
shown and the data goes to the database when I click submit? Any help
is greatly appreciated.

Thanks,
BenIf you look at the ASP.NET QUICKSTART tutorials on the asp.net website, it
has lots of examples like this. QUICKSTARTS also installs as an option with
Visual Studio.
--
--Peter
"Inside every large program, there is a small program trying to get out."
http://www.eggheadcafe.com
http://petesbloggerama.blogspot.com
http://www.blogmetafinder.com
"Ben" wrote:

Quote:

Originally Posted by

I have an ASP.Net page created with a table I made to look like a form
for our benefit request program. How do I code this properly to send
it to a table in our database.
>
For the sake of me learning how to do this lets just do short example
like. I have an aspx page with a label for name and a text box where
a user can input their name.
>
I have a database table called tblName with a column called name where
the submitted names go.
>
How do I code it so the name is submitted, a confirmation page is
shown and the data goes to the database when I click submit? Any help
is greatly appreciated.
>
Thanks,
Ben
>

Submitting Form to Database

I have an ASP.Net page created with a table I made to look like a form
for our benefit request program. How do I code this properly to send
it to a table in our database.
For the sake of me learning how to do this lets just do short example
like. I have an aspx page with a label for name and a text box where
a user can input their name.
I have a database table called tblName with a column called name where
the submitted names go.
How do I code it so the name is submitted, a confirmation page is
shown and the data goes to the database when I click submit? Any help
is greatly appreciated.
Thanks,
BenIf you look at the ASP.NET QUICKSTART tutorials on the asp.net website, it
has lots of examples like this. QUICKSTARTS also installs as an option with
Visual Studio.
--
--Peter
"Inside every large program, there is a small program trying to get out."
http://www.eggheadcafe.com
http://petesbloggerama.blogspot.com
http://www.blogmetafinder.com
"Ben" wrote:

> I have an ASP.Net page created with a table I made to look like a form
> for our benefit request program. How do I code this properly to send
> it to a table in our database.
> For the sake of me learning how to do this lets just do short example
> like. I have an aspx page with a label for name and a text box where
> a user can input their name.
> I have a database table called tblName with a column called name where
> the submitted names go.
> How do I code it so the name is submitted, a confirmation page is
> shown and the data goes to the database when I click submit? Any help
> is greatly appreciated.
> Thanks,
> Ben
>

Monday, March 26, 2012

Suggestion for an "imagemap-like" location feature -- methods?

Hi, I'm creating an asp.net application and one of the functions I need
is to click on a "Where Is This Office Located?" button. In a table,
each employee will have an office code location entered.
I then need to have the office layout image load and have the name of
that person highlighted such as bold/red (in the correct office
location).
Similar to an image map, but not quite. I do not want to click on an
office "hotspot" and go to a URL. Not finding anything in my searches
other than typical image map methods.
Any guidance or suggestions much appreciated!
Thanks, Kat
*** Sent via Developersdex http://www.examnotes.net ***
Don't just participate in USENET...get rewarded for it!Hi Kat,
Actually, nothing at all like an image map. Just an image. However, it has
to be dynamically-generated, as you want to "draw on it."
Let's analyze your requirements:
1. A user clicks on a link or button, or selects an item from a drop-down
list , or what-have-you. (I don't know which you would rather use)
2. A database is queried to get the file location of the appropriate image
and/or information from the database.
3. An office layout image is returned, with the user's name drawn on itin
bold/red letters.
Okay, so you can figure out number 1 for yourself. As for number 2 and 3:
a. The database is queried. Easy enough.
b. The image is fetched from its file location. Easy enough.
c. The image is drawn on. This is done using the System.Drawing and
System.Drawing.Imaging namespaces.
d. The image is returned to the browser. This requires that the image URL
point to an ASPX page that fetches the image, draws on it, sets the
Response.ContentType to "image/jpeg" (whatever MIME type you need), and
saves the image to the Response.OutputStream.
Okay, wait a second. We nede to back up. First, you need to identify the
user. This can be done with a "login" form in which the user supplies a user
id and password, and the data is stored on the server (Session, database,
Application Cache, etc).
That should do it!
HTH,
Kevin Spencer
Microsoft MVP
.Net Developer
Neither a follower nor a lender be.
"KatB" <nospam@.comcast.net> wrote in message
news:ebePmxb%23EHA.1296@.TK2MSFTNGP10.phx.gbl...
> Hi, I'm creating an asp.net application and one of the functions I need
> is to click on a "Where Is This Office Located?" button. In a table,
> each employee will have an office code location entered.
> I then need to have the office layout image load and have the name of
> that person highlighted such as bold/red (in the correct office
> location).
> Similar to an image map, but not quite. I do not want to click on an
> office "hotspot" and go to a URL. Not finding anything in my searches
> other than typical image map methods.
> Any guidance or suggestions much appreciated!
> Thanks, Kat
> *** Sent via Developersdex http://www.examnotes.net ***
> Don't just participate in USENET...get rewarded for it!
Kevin, very helpful, thanks. If I use a floor plan image with all the
office names already on it, and then just add a star graphic or
something to indicate the position requested...how would I know the
position of where to draw the star?
I assume I would have a db table of person, office number, and then the
coordinates of the "star". How would I determine those coordinates?
Sorry, if I'm being stupid!
In the meantime, I'll go read up on system.drawing having not used it
before.
Thanks, Kat
*** Sent via Developersdex http://www.examnotes.net ***
Don't just participate in USENET...get rewarded for it!
Hi Kat, there's a good layer of dust in this part of my mental technical
archives, so I leave the implementation details to you.
As I recall, the original image map technology, which I remember being
referred to as "server side imagemaps", could be used to determine the X, Y
coordinate within an image that a user clicked on. It was fairly
straightforward; you add a tag to your image (ISMAP, maybe) and a Url, and
when the user clicks somewhere on the image, a hit is made to your Url.
Again lots of dust here; check this carefully but I recall that the Url was
in a nonstandard format, something like;
/somepage.aspx?23,48
I.e. you have a querystring but it's not a typical key-value querystring.
You'll need to process it a little differently; grab the entire querystring
and split on the comma, or something similar.
The point is, it should be easy to create an administration page that allows
you to modify the details of an Office record.
Within this page, you could show the floorplan contain the star of the
current location of the office. Then if the admin-user clicks on the
imagemap, you capture the new X, Y, and update the Office record.
This is about the cheapest, crudest, simplest way I can think of to capture
image coordinates through a web app.
If you're lucky, there may be some javascript that can respond to the click,
and allow you to create a true ASP.NET control using true ASP.NET postbacks
and so on. If you're fantastically lucky, someone may have done this for
you already.
The trickiest part will be making sure that you know the OfficeID that the
X, Y should be applied to on the receiving page. You may need to insert the
OfficeID into the Url that's posted back to, so that you can process it out
at the receiving end. On that note, the Hyperlink control may give you the
capabilities you need, or you may be able to derive from it to get the right
capabilities.
Other approaches;
+ Use Flash
+ Use a WinForms application for capturing the X, Y clicks and updating the
Office records
+ Use ASP.NET but give the user some up, down, left, right arrows rather
than the ability to click on the image.
+ Use ASP.NET but put a series of small clickable carats along the top and
left of the floorplan image. These would be standard LinkButtons with a
small graphical carat. Clicking these would set the X or Y, respectively to
a value matching the position of the carat.
+ Build an ActiveX control
+ Build a .NET winforms control that's delivered to the webpage (the user
must have .NET installed however).
HTML is quite limited from this perspective, but I'm fairly certain the
tools are there if you're willing to make them work.
Best of luck;
/// M
"KatB" <nospam@.comcast.net> wrote in message
news:eZdOOVk#EHA.3616@.TK2MSFTNGP11.phx.gbl...
> Kevin, very helpful, thanks. If I use a floor plan image with all the
> office names already on it, and then just add a star graphic or
> something to indicate the position requested...how would I know the
> position of where to draw the star?
> I assume I would have a db table of person, office number, and then the
> coordinates of the "star". How would I determine those coordinates?
> Sorry, if I'm being stupid!
> In the meantime, I'll go read up on system.drawing having not used it
> before.
> Thanks, Kat
> *** Sent via Developersdex http://www.examnotes.net ***
> Don't just participate in USENET...get rewarded for it!
If you are open to use of commercial components to aid
in your project our MetaDraw control may be helpful
In MetaDraw you would have the office map created along with the
names of the all different individuals as text objects at their proper
locations. Save this layout as a MetaDraw data file. This is
all done ahead of time. Then when user clicks in a list on
a name you want to highlight you can tell MetaDraw to either
Hide all names but the desired name, or show all names but
only highlight ( bold or a bright color ) the desired name.
MetaDraw can be used server side in which case you have
MetaDraw save the resulting image ( with highlighted name, etc)
as a standard GIF, JPG, or PNG file and send that down to
the client. A more flexible approach is to use MetaDraw client
side - Sending the whole layout with all names, and then have
client side script hide or show the names, or even blink a name
on or off. You could also change the color of the room boundaries,
Scroll, Zoom, Print... etc.
Take a look at www.Bennet-Tec.com
Reply here if this seems like something of interest.
* * Please include a copy of this message with your reply
Jeff Bennett
Jeff @. Bennet-Tec.Com
* Bennet-Tec Information Systems, Inc
* 50 Jericho Tpk, Jericho, NY 11753
* Phone 516 997 5596, Fax - 5597
* RELIABLE Components Make You Look Sharp!
* TList/Pro * ALLText HT/Pro * MetaDraw *
* Custom Software Development Services Too.
* WWW.Bennet-Tec.Com
=================== ===================

Suggestion for an "imagemap-like" location feature -- methods?

Hi, I'm creating an asp.net application and one of the functions I need
is to click on a "Where Is This Office Located?" button. In a table,
each employee will have an office code location entered.

I then need to have the office layout image load and have the name of
that person highlighted such as bold/red (in the correct office
location).

Similar to an image map, but not quite. I do not want to click on an
office "hotspot" and go to a URL. Not finding anything in my searches
other than typical image map methods.

Any guidance or suggestions much appreciated!

Thanks, Kat

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!Hi Kat,

Actually, nothing at all like an image map. Just an image. However, it has
to be dynamically-generated, as you want to "draw on it."

Let's analyze your requirements:

1. A user clicks on a link or button, or selects an item from a drop-down
list , or what-have-you. (I don't know which you would rather use)
2. A database is queried to get the file location of the appropriate image
and/or information from the database.
3. An office layout image is returned, with the user's name drawn on itin
bold/red letters.

Okay, so you can figure out number 1 for yourself. As for number 2 and 3:

a. The database is queried. Easy enough.
b. The image is fetched from its file location. Easy enough.
c. The image is drawn on. This is done using the System.Drawing and
System.Drawing.Imaging namespaces.
d. The image is returned to the browser. This requires that the image URL
point to an ASPX page that fetches the image, draws on it, sets the
Response.ContentType to "image/jpeg" (whatever MIME type you need), and
saves the image to the Response.OutputStream.

Okay, wait a second. We nede to back up. First, you need to identify the
user. This can be done with a "login" form in which the user supplies a user
id and password, and the data is stored on the server (Session, database,
Application Cache, etc).

That should do it!

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Neither a follower nor a lender be.

"KatB" <nospam@.comcast.net> wrote in message
news:ebePmxb%23EHA.1296@.TK2MSFTNGP10.phx.gbl...
> Hi, I'm creating an asp.net application and one of the functions I need
> is to click on a "Where Is This Office Located?" button. In a table,
> each employee will have an office code location entered.
> I then need to have the office layout image load and have the name of
> that person highlighted such as bold/red (in the correct office
> location).
> Similar to an image map, but not quite. I do not want to click on an
> office "hotspot" and go to a URL. Not finding anything in my searches
> other than typical image map methods.
> Any guidance or suggestions much appreciated!
> Thanks, Kat
> *** Sent via Developersdex http://www.developersdex.com ***
> Don't just participate in USENET...get rewarded for it!
Kevin, very helpful, thanks. If I use a floor plan image with all the
office names already on it, and then just add a star graphic or
something to indicate the position requested...how would I know the
position of where to draw the star?

I assume I would have a db table of person, office number, and then the
coordinates of the "star". How would I determine those coordinates?
Sorry, if I'm being stupid!

In the meantime, I'll go read up on system.drawing having not used it
before.

Thanks, Kat

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Hi Kat, there's a good layer of dust in this part of my mental technical
archives, so I leave the implementation details to you.

As I recall, the original image map technology, which I remember being
referred to as "server side imagemaps", could be used to determine the X, Y
coordinate within an image that a user clicked on. It was fairly
straightforward; you add a tag to your image (ISMAP, maybe) and a Url, and
when the user clicks somewhere on the image, a hit is made to your Url.
Again lots of dust here; check this carefully but I recall that the Url was
in a nonstandard format, something like;

/somepage.aspx?23,48

I.e. you have a querystring but it's not a typical key-value querystring.
You'll need to process it a little differently; grab the entire querystring
and split on the comma, or something similar.

The point is, it should be easy to create an administration page that allows
you to modify the details of an Office record.

Within this page, you could show the floorplan contain the star of the
current location of the office. Then if the admin-user clicks on the
imagemap, you capture the new X, Y, and update the Office record.

This is about the cheapest, crudest, simplest way I can think of to capture
image coordinates through a web app.

If you're lucky, there may be some javascript that can respond to the click,
and allow you to create a true ASP.NET control using true ASP.NET postbacks
and so on. If you're fantastically lucky, someone may have done this for
you already.

The trickiest part will be making sure that you know the OfficeID that the
X, Y should be applied to on the receiving page. You may need to insert the
OfficeID into the Url that's posted back to, so that you can process it out
at the receiving end. On that note, the Hyperlink control may give you the
capabilities you need, or you may be able to derive from it to get the right
capabilities.

Other approaches;

+ Use Flash
+ Use a WinForms application for capturing the X, Y clicks and updating the
Office records
+ Use ASP.NET but give the user some up, down, left, right arrows rather
than the ability to click on the image.
+ Use ASP.NET but put a series of small clickable carats along the top and
left of the floorplan image. These would be standard LinkButtons with a
small graphical carat. Clicking these would set the X or Y, respectively to
a value matching the position of the carat.
+ Build an ActiveX control
+ Build a .NET winforms control that's delivered to the webpage (the user
must have .NET installed however).

HTML is quite limited from this perspective, but I'm fairly certain the
tools are there if you're willing to make them work.

Best of luck;

/// M

"KatB" <nospam@.comcast.net> wrote in message
news:eZdOOVk#EHA.3616@.TK2MSFTNGP11.phx.gbl...
> Kevin, very helpful, thanks. If I use a floor plan image with all the
> office names already on it, and then just add a star graphic or
> something to indicate the position requested...how would I know the
> position of where to draw the star?
> I assume I would have a db table of person, office number, and then the
> coordinates of the "star". How would I determine those coordinates?
> Sorry, if I'm being stupid!
> In the meantime, I'll go read up on system.drawing having not used it
> before.
> Thanks, Kat
> *** Sent via Developersdex http://www.developersdex.com ***
> Don't just participate in USENET...get rewarded for it!
If you are open to use of commercial components to aid
in your project our MetaDraw control may be helpful

In MetaDraw you would have the office map created along with the
names of the all different individuals as text objects at their proper
locations. Save this layout as a MetaDraw data file. This is
all done ahead of time. Then when user clicks in a list on
a name you want to highlight you can tell MetaDraw to either
Hide all names but the desired name, or show all names but
only highlight ( bold or a bright color ) the desired name.

MetaDraw can be used server side in which case you have
MetaDraw save the resulting image ( with highlighted name, etc)
as a standard GIF, JPG, or PNG file and send that down to
the client. A more flexible approach is to use MetaDraw client
side - Sending the whole layout with all names, and then have
client side script hide or show the names, or even blink a name
on or off. You could also change the color of the room boundaries,
Scroll, Zoom, Print... etc.

Take a look at www.Bennet-Tec.com

Reply here if this seems like something of interest.

* * Please include a copy of this message with your reply

Jeff Bennett
Jeff @. Bennet-Tec.Com

* Bennet-Tec Information Systems, Inc
* 50 Jericho Tpk, Jericho, NY 11753
* Phone 516 997 5596, Fax - 5597
* RELIABLE Components Make You Look Sharp!
* TList/Pro * ALLText HT/Pro * MetaDraw *
* Custom Software Development Services Too.
* WWW.Bennet-Tec.Com
=================== ===================

Suggestion on shopping cart and sessions

Hi,
I am working on implementing a shopping cart. I am planning to storethe shopping cart items in a database table. A shoppingcartid will beused to distinguish between different shopping carts. Theshoppingcartid for members will be their userid, for others it will bea guid. I am planning to store the shoppingcartid in a sessionvariable. We don't have a webfarm, just one server machine. I amthinking of using session with InProc mode.
But I have read many posts complaining of expired sessions, sessiontimeouts, session_end not fired etc. Is it ok to use sessions to storethe cartid or is there any better solution?
Thanks.

If your serious and in a hurry, SQL Server is the easy way. the other options are to write your own or use another server.

There is no session end when running SQL Server session


You said 'to write your own'. Can you please ecplain more on that. Thanks.

Sadly, time does not permit, but have a look at this - it should help

http://www.codeproject.com/aspnet/StateHijack.asp


Thanks.
Can any one tell me is there any major downside of using cookies tostore the cartid instead of sessions? I think there will be moreabondoned carts than when using sessions. But I am not concerned aboutthat.
I think may be you could use a temp table to store your data,you can delete the expired data automaticlly

hello.

or maybe you should consider taking a look at profiles.


I am not using ASP.Net 2.0 I cannot use profiles.

Saturday, March 24, 2012

Suggestions on how to ...

Can anyone suggest a good way of achieving the following;

I have a database table that contains say 30 records. I want my user to be able to view a list of all of these records and then select which ones they want to appear in a report. So they might select only one record, they might select 5 different ones. I want the records they selected to appear in one place on the screen and the others to appear elsewhere at the same time. Then they click on a button and my code uses the primary keys of only the selected records to extract data from my table.

I think you might be able to achieve this by using two listboxes side-by-side in an html table but the text that the user will need to identify the record is going to be over 200 characters long.

Thanks in advance.Have you considered using a datagrid? Do you know how to? Datagrids also allow you to wrap your text in a cell onto the next line.

Summary of data in ASP.NET

hello

i am pretty new to asp.net and would like advice on how to best summarise data from an sql server database.

i have some data in a table, each record containing someones name and a 'type' field (contains positive or negative) among other stuff . i need to summarise the count of how many times a persons name appears in the table and display how many positive/negative entries there are.

i've used VB6 and VBA for ages and know how to do this by stepping through recordsets etc but want to know what the best approach is in ADO.NET, i'm still trying to get my head round data readers, datassets, data adapters, data tables etc.

any help is greatly appreciated
thanks
mickThis aggregation would probably be best left to your SQL engine of choice.

Based on the table:

PersonName varchar(50)
Active bit

With the values

PersonName Active
Tom 0
Tom 0
Tom 1
Jane 1
Jim 0

The query:

SELECT PersonName, COUNT(PersonName) HitCount, Active
FROM Person
GROUP BY PersonName, Active
ORDER BY PersonName

Should result in:

PersonName HitCount Active
Jane 1 1
Jim 1 0
Tom 2 0
Tom 1 1

From here, any tutorial on querying a database via SQL (a data reader should be fine) should apply.
thanks very much.

Tuesday, March 13, 2012

Survey: What do you name your User table?

Most of the sites that I build have to deal with security at some
point, and this means that somewhere in the database there needs to be
a list of Users.

The naming convention that I (and most everybody I've ever worked with
that cares about such things) use dictates that a table should be named
according to what it contains, and that this name should be singular.
So, Customer, User, Entry are all good, while Customers, Users, Entries
are not so good. Thus, nobody has to deal with Junior Dev Jimmy's
magic ID generation code that occasionally tries to bind a column to
"EntrieID".

The issue I keep running into is that "User" is essentially a reserved
word in ASP.NET, being a property of Page. Thus, I can't use it as the
ClassName for my DataObject that wraps the User table. Thus, I
probably shouldn't be naming the table "User", since every other
DataObject always is named after the table it represents.

I've tried going with "Login" to describe users, but this usually
crashes into somebody's Login.aspx Page object, and besides it's not
quite descriptive enough for my tastes.

That leaves us with "Users" (thus breaking our naming convention),
"tblUser" "UserTable" or "UserRecord" (which all look silly on the
url), "Individual" or "Dude" (which I've actually gone with in the
past).

I'm curious what other people have come up with to attack this problem.
I'm sure I'm not the only one running into it. Let me know what you
think!

Jason Kester
Expat Software Consulting Services
http://www.expatsoftware.com/because tables are sets, i (like the sqlserver dev group) always make them
pural, so my users table name is Users. in your case UserInfo is probably a
good name.

-- bruce (sqlwork.com)

"jasonkester" <jasonkester@.gmail.com> wrote in message
news:1125699677.612465.206070@.g43g2000cwa.googlegr oups.com...
> Most of the sites that I build have to deal with security at some
> point, and this means that somewhere in the database there needs to be
> a list of Users.
> The naming convention that I (and most everybody I've ever worked with
> that cares about such things) use dictates that a table should be named
> according to what it contains, and that this name should be singular.
> So, Customer, User, Entry are all good, while Customers, Users, Entries
> are not so good. Thus, nobody has to deal with Junior Dev Jimmy's
> magic ID generation code that occasionally tries to bind a column to
> "EntrieID".
> The issue I keep running into is that "User" is essentially a reserved
> word in ASP.NET, being a property of Page. Thus, I can't use it as the
> ClassName for my DataObject that wraps the User table. Thus, I
> probably shouldn't be naming the table "User", since every other
> DataObject always is named after the table it represents.
> I've tried going with "Login" to describe users, but this usually
> crashes into somebody's Login.aspx Page object, and besides it's not
> quite descriptive enough for my tastes.
> That leaves us with "Users" (thus breaking our naming convention),
> "tblUser" "UserTable" or "UserRecord" (which all look silly on the
> url), "Individual" or "Dude" (which I've actually gone with in the
> past).
> I'm curious what other people have come up with to attack this problem.
> I'm sure I'm not the only one running into it. Let me know what you
> think!
>
> Jason Kester
> Expat Software Consulting Services
> http://www.expatsoftware.com/
UserProfile, UserRegistrationInfo, RegisteredUsers, UserCredentials...

Johm

Survey: What do you name your User table?

Most of the sites that I build have to deal with security at some
point, and this means that somewhere in the database there needs to be
a list of Users.
The naming convention that I (and most everybody I've ever worked with
that cares about such things) use dictates that a table should be named
according to what it contains, and that this name should be singular.
So, Customer, User, Entry are all good, while Customers, Users, Entries
are not so good. Thus, nobody has to deal with Junior Dev Jimmy's
magic ID generation code that occasionally tries to bind a column to
"EntrieID".
The issue I keep running into is that "User" is essentially a reserved
word in ASP.NET, being a property of Page. Thus, I can't use it as the
ClassName for my DataObject that wraps the User table. Thus, I
probably shouldn't be naming the table "User", since every other
DataObject always is named after the table it represents.
I've tried going with "Login" to describe users, but this usually
crashes into somebody's Login.aspx Page object, and besides it's not
quite descriptive enough for my tastes.
That leaves us with "Users" (thus breaking our naming convention),
"tblUser" "UserTable" or "UserRecord" (which all look silly on the
url), "Individual" or "Dude" (which I've actually gone with in the
past).
I'm curious what other people have come up with to attack this problem.
I'm sure I'm not the only one running into it. Let me know what you
think!
Jason Kester
Expat Software Consulting Services
http://www.expatsoftware.com/because tables are sets, i (like the sqlserver dev group) always make them
pural, so my users table name is Users. in your case UserInfo is probably a
good name.
-- bruce (sqlwork.com)
"jasonkester" <jasonkester@.gmail.com> wrote in message
news:1125699677.612465.206070@.g43g2000cwa.googlegroups.com...
> Most of the sites that I build have to deal with security at some
> point, and this means that somewhere in the database there needs to be
> a list of Users.
> The naming convention that I (and most everybody I've ever worked with
> that cares about such things) use dictates that a table should be named
> according to what it contains, and that this name should be singular.
> So, Customer, User, Entry are all good, while Customers, Users, Entries
> are not so good. Thus, nobody has to deal with Junior Dev Jimmy's
> magic ID generation code that occasionally tries to bind a column to
> "EntrieID".
> The issue I keep running into is that "User" is essentially a reserved
> word in ASP.NET, being a property of Page. Thus, I can't use it as the
> ClassName for my DataObject that wraps the User table. Thus, I
> probably shouldn't be naming the table "User", since every other
> DataObject always is named after the table it represents.
> I've tried going with "Login" to describe users, but this usually
> crashes into somebody's Login.aspx Page object, and besides it's not
> quite descriptive enough for my tastes.
> That leaves us with "Users" (thus breaking our naming convention),
> "tblUser" "UserTable" or "UserRecord" (which all look silly on the
> url), "Individual" or "Dude" (which I've actually gone with in the
> past).
> I'm curious what other people have come up with to attack this problem.
> I'm sure I'm not the only one running into it. Let me know what you
> think!
>
> Jason Kester
> Expat Software Consulting Services
> http://www.expatsoftware.com/
>
UserProfile, UserRegistrationInfo, RegisteredUsers, UserCredentials...
Johm

switch tables according to user input

i want to insert data in a particular table which i ask the user

how can i switch between database tables according to user input

Can you give more information about what you trying to do. What kind of input textbox, radio button, checkbox... Are they submitting something or are you wanting to do this on the fly?
You'd have to use dynamic SQL.