|
Update FileTable
Set FileName = replace(FileName, '-', '_')
You have an arrow in your butt!
My name is Maximus Decimus Meridius, Commander of the Armies of the North, General of the Felix Legions, loyal servant to the true emperor, Marcus Aurelius. Father to a murdered process, husband to a murdered thread. And I will have my affinity, in this life or the next. - Gladiator. (Okay, not quite Gladiator but close.)
I work to live. I do not live to work. My clients do not seem capable of grasping this fact.
Ancient of days! august Athena! where, Where are thy men of might? - Lord Byron
|
|
|
|
|
Hi every one,
I installed SQL server 2005 enterprise edition on my pc and I selected SQLEXPRESS name for instance of it .I have a vb program and I can connect to database with below connection string.
SqlCon.ConnectionString = "Driver={SQL Server};Server=ComputeName\SQLEXPRESS;DataBase=DigitalSignature;Trusted_Connection=Yes;"
ComputerName is the name of my Computer and DigitalSignature is the name of my database in sql server.
My problem is :when my pc is connected to network I can connect to database completely but when I disconnect the pc from network I get error .
How can I connect to sql server from an application that both of them(Sql server and Application) are in one computer.I think the connection string is wrong.
If any one knows ,please inform me.
yours sincerely,
Orchid
|
|
|
|
|
Orchid85 wrote: I installed SQL server 2005 enterprise edition on my pc and I selected SQLEXPRESS name for instance of it
Why did your ENTERPRISE edition of SQL Server SQLEXPRESS? That makes no sense.
Orchid85 wrote: My problem is :when my pc is connected to network I can connect to database completely but when I disconnect the pc from network I get error .
What error? (Why do people insist on writing to a forum to say they have an error, but expect the world to guess what the error message is?! WE ARE NOT TELEPATHIC!)
Orchid85 wrote: How can I connect to sql server from an application that both of them(Sql server and Application) are in one computer.I think the connection string is wrong.
What makes you think the Connection String is wrong? It was working fine when the network was connected. Doesn't that indicate the connection string is valid?
I'm curious as to why you disconnected the network. SQL Server Enterprise Edition is designed to work in a networked environment.
I'm guessing that you need to go into the "SQL Server Configuration Manager". Go into "SQL Server Network Configuration"-->"Protocols for SQLEXPRESS" And in the right pane there will be a thing marked "Shared Memory". Right-click it and "Enable" it. That might solve your immediate problem.
|
|
|
|
|
Hi Guys,
I have a strange problem -
1) I created a dataset using data tables loaded from the SA connection string.
2) Setup these DS's and used them as test stubs with SQL squeries.
3) Created stored procs and pointed the SQL Functions at these instead.
4) Created a new user with just SP Access
5) Set the connection string to use this new user login in the connection
Now, after all this is complete, all references to the origional SA connection string have been removed, all the project Bin folders have been deleted, all the Obj folders have been cleared and the DTA's themselves say that they are using the new connection string, it still loads up using the SA connection.
Additional Info:
This is a seprate DB Library to the web project.
This project is running in Cassini.
I'm spooked. What's the deal?
Cheers
Tris
-------------------------------
Carrier Bags - 21st Century Tumbleweed.
|
|
|
|
|
Tristan Rhodes wrote: I'm spooked. What's the deal?
No idea. You have to trace where the connection string is coming from. Start with the point at which the connection is made, put a break point down at that point. Look where the connection string comes from and work backwards from there, putting break points further back in the code until you have your answer. Essentially, what you need is a break point that is set just before the connection string is generated or retrieved. Then you step into as much code to see what is happening as possible.
|
|
|
|
|
Weird
Seems my settings file wasn't updated.
Weird that nothing picked up on it, i did so many full text searches that i was certain it couldn't have existed. Just clicked on the settings file and it auto updated from the config.
That'd be my Inexcusable Stupid Noobie Mistake (tm) 1'567'445
Edit: No wonder i didn't find it - VB did a lovely '& _' line break in the middle of it.
-------------------------------
Carrier Bags - 21st Century Tumbleweed.
|
|
|
|
|
Hi all,
How do I make the date format to DD-MMM-YYY, ie. 01-APR-1998.
I have try to set 'DateStyle' to all options but none of them can show
this format.
Could someone help me please?
Suresh.R
|
|
|
|
|
What technology are you using? (That would be a help to finding your answer)
|
|
|
|
|
Hi
i want it in SQL...
my INPUT is GetDate() and
OUTPUT is 9-Apr-2007...ok..
Suresh.R
|
|
|
|
|
sooreeagt wrote: i want it in SQL...
All RDBMS support SQL. Did you mean Microsoft SQL Server?
If you meant SQL Server then there is no exact conversion to the format you want. Be aware that it is the responsibility of the Presentation layer to format data, not the database.
|
|
|
|
|
Hey to Crystal Report users
i have made report with crystal report viewer and crystal report tool but before i get the report wich one i can print.it is asking me the DATABASE password which i dont want the End user to know ?
Please help me
i just want the user to click on print button and get the report without the database authentication
ok
job
|
|
|
|
|
ON button click.
-- 1. First make the object of the report (say AA.rpt)
Dim obj As New AA
-- 2. Pass the database (userid,pwd, server, Database name)
obj.SetDatabaseLogon("sa", "sa", "10.179.10.38", "PUBS")
-- 3. Use the object of crystal report viewer.
crViewer.ReportSource = obj
crViewer.Visible = True
vivek
|
|
|
|
|
Is there a sql query which will help me get the names of all the tables in the database.
|
|
|
|
|
SELECT * FROM INFORMATION_SCHEMA.TABLES
|
|
|
|
|
If you are doing it from code you could use the GetSchema("Databases") command off of the sqlconnection.
_____________________________________________________________________
Our developers never release
code. Rather, it tends to escape, pillaging the countryside all around.
The Enlightenment Project (paraphrased comment)
Visit Me at GISDevCafe
|
|
|
|
|
Hi..
Try the following query..
select * from sysobjects where xtype='u'
Balaguru
|
|
|
|
|
Nothing is working. My db name is siebeldb and presently there is only 1 table in it, namely 'orders'. But knowing that siebeldb is the database, how do I get the names of the tables it contains. Also when I know a table, how do I get the fieldnames and fieldtypes in the table.
|
|
|
|
|
izzit possible to do this?
(SELECT NAME FROM STAFF)//first statement
-
(SELECT NAME FROM HUMAN WHERE NAME LIKE 'A')//2nd statement
of coz this is not the actual statment but my staement is somewhat alike
i can generate a table of the infomation i dont need :
ABC
AAA
and i can also generate all the infomation
ABC
AAA
BBB
however what i need is :
BBB
|
|
|
|
|
the query to be used is ....
SELECT name FROM staff WHERE name NOT IN (SELECT name FROM hanuman WHERE name LIKE 'A' )
Regards
KP
|
|
|
|
|
in my previous question i asked how to get date
so now i was wondering how can i compare date?
SELECT NAME, DATE_TIME
FROM STUFF
WHERE ()<-- not sure
do i use DATE_TIME > get_date()?
or something else please help
|
|
|
|
|
Hi,
you can use the following WHERE clause,
MyDate = CONVERT(DATETIME, '2007-03-27 00:00:00', 102)
or
MyDate = getdate()
Mubashir
Every job is a self portrait of the person who did it.
|
|
|
|
|
Data type date is not available in SQL server
however DateTime is available
so if table Stuff is updated with
INSERT INTO stuff VALUES('Mr. X', '01-Jan-2007')
INSERT INTO stuff VALUES('Mr. X', getdate())
and while fetching
SELECT * FROM staff WHERE date_time = getdate()
returns no rows i.e. both rows would not be returned. because getdate() returns date & time
In this case need to take only date protion and compare or compare day, month, year separately.
Regards
KP
|
|
|
|
|
Krish - KP wrote: SELECT * FROM staff WHERE date_time = getdate()
returns no rows i.e. both rows would not be returned. because getdate() returns date & time
It returns no rows because all dates in the database occur in the past, therefore there is no match. It has nothing to do with the fact that GETDATE() returns the date and time.
If you only stored the date portion then the time portion will always be midnight. You can use that information to your benefit when writing calculation.
|
|
|
|
|
Hello
VS 2005
I have been looking at transactions to rollback if 1 of my insert or updates does not complete successfully.
Code example:
<br />
dim ts as new transactionScope()<br />
<br />
'Insert a record into table A<br />
'Insert a record into table B <br />
'update table C<br />
ts.Complete()<br />
The above does not work too well with my code. I am wondering is there a better way to manage transactions.
Many thanks for any advice,
Steve
|
|
|
|
|
hi my questions is that in the case where my datasource have no result (becasue of the parameter there are no result) i want to route it to another sql statment is it possible??
my code below:
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:asdConnectionString1 %>"<br />
<br />
SelectCommand="SELECT DISTINCT AuctionSessionID, LocationID, Date_Time, AuctionDescription, Comments FROM AuctionSession WHERE (AuctionSessionID <> (SELECT AuctionSession FROM Registration WHERE (NRIC = @NRIC)))"<br />
|
|
|
|