|
I migrate the microsoft class : SqlHelper to OracleHelper, i used in this class ODP .NET 10..
I need some person to do the test. if there is someone who is interested by this this request ,please send me an email
at nizar@myway.com and i will response him.
thnx
ENSI TUNISIA
|
|
|
|
|
Ok. In C++ I have code that passed coded in SQL statements that update data/time fields like so:
"UPDATE mytable SET f_date1='05/04/2005 12:01:02'". So the obvious problem is that if windows set to anything (or close to anything) other than USA region the date gets reversed in the DB itself. So when I query this field again it's '04/05/2005'. So is there an easy way to go around this? Or do I have to reformat SQL statement for each region?
Urgent!!! Please help!!!
Thanks a lot in advance!
|
|
|
|
|
|
How could i create a table with a passed parameter,
something like that
CREATE PROCEDURE TaoBang
@TenBang char(10)
AS
CREATE TABLE @TenBang
(
ID char(10) primary key
subname char(10)
)
Thank you so much
if i've got a better way to do that, please show me
|
|
|
|
|
You need to create a string that represents the SQL you want to run, and then pass it to exec.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
CREATE PROCEDURE TaoBang<br />
@TenBang char(10)<br />
AS<br />
<br />
declare @sql varchar(100)<br />
set @sql= 'CREATE TABLE ' + @TenBang + '<br />
(<br />
ID char(10) primary key,<br />
subname char(10) <br />
)'<br />
exec (@sql)
<italic>Work hard, Work effectively.
|
|
|
|
|
I have the following:
SELECT * FROM Article, Member, Album
LEFT JOIN
( SELECT *
FROM
linkArticleAlbum, Photo, Album
WHERE
linkArticleAlbum.Album = Photo.Album AND
linkArticleAlbum.Album = Album.ID AND
Photo.IsIcon = true ) As AlbumLink
ON AlbumLink.linkArticleAlbum.Article = Article.ID
WHERE
Article.Author = Member.ID AND
Article.Team = 1
ORDER BY Article.DateCreated DESC, Article.Title
How can I do this in Access 2002? You see that I need to get the photo that represents the icon for the album on every occasion where the article is linked with an album.
I'm stumped. I'm also a bit of a newb when it comes to subqueries and the way things are referenced.
--------
to die is gain
|
|
|
|
|
why don't you try creating the subquery and saviong as a view - then simply join the table to the query (by name) and use QBE window. Keep it simple!
|
|
|
|
|
|
i want to create a data base that include the informations of bussines centers of one city such as shopp stores and ...
what tables this database include?
what fields each table include?
i now this is not good question but please reply me?
|
|
|
|
|
Anonymous wrote:
what tables this database include?
What information do you need? You already mention shop stores. This can be a table ,"Store".
Anonymous wrote:
what fields each table include?
What does a table represents?
If your table is "Store", you might have the address, phone, items to sell, and etc.
<italic>Work hard, Work effectively.
|
|
|
|
|
I think you need to look at what information that you want to store in the database. What sort of things do you want to store information about?
Here are some things to think about:
* I would guess that maybe "business" is going to be one of your tables.
* There are many types of business, so maybe your "business" table will have a type column to store types of business. And, a type table as well so you can group businesses by type - your business table would have a foreign key reference to the key of the type table.
* Businesses will have an address, so maybe you want some address columns.
* Perhaps a business has multiple addresses, so perhaps you want to create an "address" table that contains a foreign key to the "business" table instead.
However, I cannot tell you what tables or columns you need. If you want help answering that question then you will have to tell us what you want to store.
My: Blog | Photos | Next SQL Presentation
WDevs.com - Open Source Code Hosting, Blogs, FTP, Mail and More
|
|
|
|
|
Thank you Colin Angus Mackay!
there was very good idea ?can you send me one sample like the subject i want?
|
|
|
|
|
|
Thank you Colin Angus Mackay!
there was very good idea ?can you send me one sample like the subject i want?
rohollahmahmoodiany@yahoo.com
|
|
|
|
|
Seeing the previous thread reminded me of a problem I'll face in a few days. I'm using MSDE (later it will be scaled up to SQL Server, but not for the time being) and I'll need to schedule an automatic backup (and of course, be able to restore it.)
I've seen BACKUP FROM and RESTORE TO T-SQL commands, but I tried them and couldn't restore the database.
Also, how should I schedule them? Just an SQL script? or should I write a little app that executes those commands using ADO.NET? Also, is it a must that they be run from the machine running the server?
Most of all, I'd like to know how it's done in the real world.
Any pointers or tips are appreciated!!
-- LuisR
Luis Alonso Ramos
Intelectix - Chihuahua, Mexico
Not much here: My CP Blog!
|
|
|
|
|
With SQL Server, you can create a maintence plan with the enterprise manager, the scheduling is handled by the SQL Server Agent Service. I'm not sure if MSDE has this same service, it might have?
Thats pretty much the process we've used to manage our databases.
|
|
|
|
|
Dan_P wrote:
I'm not sure if MSDE has this same service, it might have?
AFAIK, SQL Server Agent is present in MSDE, but I think I'll have to create the backup plan by hand. I remember seeing an article in MSDN but I can't find it.
-- LuisR
Luis Alonso Ramos
Intelectix - Chihuahua, Mexico
Not much here: My CP Blog!
|
|
|
|
|
Hi,
I backup my SQL server database to deploy it to another computer. But i don't know that how to restore it on the other computer. What r the steps.
Kindly help me in this regard.
Bye
EsHbAn BaHaDuR
|
|
|
|
|
* Copy the backup file on to the other computer
* In Enterprise Manager, open the tree on to the SQL Server instance running on the other computer (you may have to register the other SQL Server with your local Enterprise Manager if it is not already there - alternatively go to the Enterprise Manager on the other computer)
* Right click on the databases folder icon in Enterprise manager and select All Tasks-->Restore Database
My: Blog | Photos | Next SQL Presentation
WDevs.com - Open Source Code Hosting, Blogs, FTP, Mail and More
|
|
|
|
|
You went to Action/All Tasks/Backup Database to back it up, just underneath Backup Database, it says Restore Database.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
How get error description (message) associated with @@Error
When i use the FORMATMESSAGE function it's allways returns NULL.
Any ideas ???
------------------------------------
To study, study and only to study
|
|
|
|
|
You can lookup the sysmessages table with the errorID
|
|
|
|
|
However how can i know the details of the error such where it occurs in which line. I need something like i get in sql query analyzer.
------------------------------------
To study, study and only to study
|
|
|
|
|
I'm trying to bind a picture box to my access 2002 Db in vb.net
Here is my code
Dim b As Binding = New Binding("Image", dsComics, "comiclist.ComicCover")<br />
AddHandler b.Format, AddressOf ConvertPicture<br />
Me.picCover.DataBindings.Add(b)<br />
<br />
<br />
<br />
Public Sub ConvertPicture(ByVal Sender As Object, ByVal e As ConvertEventArgs)<br />
Dim b() As Byte = e.Value<br />
Dim ms As MemoryStream = New MemoryStream<br />
ms.Write(b, 0, b.Length)<br />
Dim bmp As Bitmap = New Bitmap(ms)<br />
ms.Close()<br />
e.Value = bmp<br />
<br />
<br />
End Sub
The line in bold is where it bombs, any ideas
BINARY
BINARY
|
|
|
|