Sign in to follow this  
Followers 0
BigDaddyO

Simple SQL Statement not working through AutoIT

2 posts in this topic

I am trying to use the sql statement IDENT_CURRENT('Table_Name') but it doesn't return anything but a diamond symbol. I am connecting to a SQL 2005 Trial edition. "It's supposed to act like the Enterprise edition"

I am able to create new records, read records, modify and delete records, but for some reason this IDENT_CURRENT will not work. :D

Here is the code I use that will give me a Diamond symbol, I have tried a lot of other combinations that just gave me errors.

$sqlCon = ObjCreate("ADODB.Connection")
$sqlCon.Open("Provider=SQLOLEDB;Server=QACOMM;Trusted_Connection=yes;")
$current = $sqlCon.execute("Select IDENT_CURRENT('HDComm')")
MsgBox(0, "Current", $current)

does anybody have any ideas?

Thanks,

Mike


Share this post


Link to post
Share on other sites



I am trying to use the sql statement IDENT_CURRENT('Table_Name') but it doesn't return anything but a diamond symbol. I am connecting to a SQL 2005 Trial edition. "It's supposed to act like the Enterprise edition"

I am able to create new records, read records, modify and delete records, but for some reason this IDENT_CURRENT will not work. :D

Here is the code I use that will give me a Diamond symbol, I have tried a lot of other combinations that just gave me errors.

$sqlCon = ObjCreate("ADODB.Connection")
$sqlCon.Open("Provider=SQLOLEDB;Server=QACOMM;Trusted_Connection=yes;")
$current = $sqlCon.execute("Select IDENT_CURRENT('HDComm')")
MsgBox(0, "Current", $current)

does anybody have any ideas?

Thanks,

Mike

I don't know a thing about SQL, so I have no idea if your coding is correct or not. But, have you considered that the return could be ASCII and needs to be converted? Just a thought.

Nomad :D


Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0