SQL script - preCharge Forums
It shows that you are unregistered. Please register with us by clicking Here
preCharge Forums


Nav Green LeftNav Right
preCharge Forums > Website Design & Development > Programming » SQL script


Reply
Tcat Right
 
LinkBack Thread Tools Display Modes Tcat Right
Old 09-28-2006   #1 (permalink)
shavei7
Senior Member
 
shavei7's Avatar
 
Join Date: Jul 2006
Location: Redmond, WA
Posts: 1,064
Default SQL script

how good are you in SQL scripting? on a scale of 1 to 10 when it comes to TSQL, how do you rate? just curious....
__________________
NOSH1T/LOSTGIRLWONDERINGV4
the only real mistake is the one from which we learn nothing (John Powell)
shavei7 is offline   Reply With Quote


Old 09-30-2006   #2 (permalink)
mann3r
Senior Member
 
Join Date: Jul 2006
Location: http://www.allseocontest.com/dir/
Age: 29
Posts: 1,047
Default Re: SQL script

can we make the range from 0-10, lol, 0 for me, well just kidding, next to zero maybe 1.
mann3r is offline   Reply With Quote

Old 09-30-2006   #3 (permalink)
shavei7
Senior Member
 
shavei7's Avatar
 
Join Date: Jul 2006
Location: Redmond, WA
Posts: 1,064
Default Re: SQL script

then never mind. i have a question to ask that nobody seem to know the answer. i've been looking up books and searching the net but still nada. freaking frustrating *grrr*

if anybody else knows this answer to this one post away pls!

you have a stored proc that should return an ID that was just created

table:
ID - auto increment
name - varchar(50)

create procedure getID
as
insert into table1 (name) values ('joe')
return @@ ---- ?? // should return the newly generated unique ID by the database

i was told there's a function that does this but even the guy who told me this couldn't remember what it is....
__________________
NOSH1T/LOSTGIRLWONDERINGV4
the only real mistake is the one from which we learn nothing (John Powell)
shavei7 is offline   Reply With Quote

Old 10-03-2006   #4 (permalink)
shavei7
Senior Member
 
shavei7's Avatar
 
Join Date: Jul 2006
Location: Redmond, WA
Posts: 1,064
Default Re: SQL script

wooh0o! a friend was able to find the answer on a book. the function that returns the auto-incremented id is @@IDENTITY. solved :)
__________________
NOSH1T/LOSTGIRLWONDERINGV4
the only real mistake is the one from which we learn nothing (John Powell)
shavei7 is offline   Reply With Quote

Old 10-12-2006   #5 (permalink)
ScottHughes
Senior Member
 
Join Date: Sep 2006
Age: 22
Posts: 460
Default Re: SQL script

Is TSQL used the same as mySQL? What's the difference?
__________________
ScottHughes is offline   Reply With Quote

Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
The best CMS script mann3r Content Management 20 09-02-2008 07:04 PM
Script Accessibility? Nazir JavaScript 3 10-12-2006 03:22 AM
VB Script Tutorial Ankita Programming 0 08-05-2006 11:07 AM
truth about script filtering polarisxtx All Things General 6 05-18-2006 05:16 AM


footer left
All times are GMT. The time now is 06:50 AM.

DISCLAIMER: preCharge Risk Management is not responsible for any opinions, advice or comments expressed on the preCharge Community Forums.
preCharge® is a registered trademark of preCharge Risk Management | chargeback protection | Merchant Account Blog

Powered by vBulletin
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0 RC6

Loans | Credit Card Consolidation | Loan | Loans | Mobile Phones

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49