SORU
26 Mart 2010, Cuma


Alter tablo ms sql birden çok sütun ekleyin

Herkes aşağıdaki sorguda hata nerede acaba

ALTER TABLE Countries
ADD ( 
HasPhotoInReadyStorage  bit,
 HasPhotoInWorkStorage  bit,
 HasPhotoInMaterialStorage bit,
 HasText  bit);

ALTER TABLE Regions
ADD ( HasPhotoInReadyStorage  bit,
 HasPhotoInWorkStorage  bit,
 HasPhotoInMaterialStorage bit
 HasText  bit);

ALTER TABLE Provinces
ADD ( HasPhotoInReadyStorage  bit,
 HasPhotoInWorkStorage  bit,
 HasPhotoInMaterialStorage bit
 HasText  bit);


ALTER TABLE Cities
ADD ( HasPhotoInReadyStorage  bit,
 HasPhotoInWorkStorage  bit,
 HasPhotoInMaterialStorage bit
 HasText  bit);

Alter table Hotels
Add 
{
 HasPhotoInReadyStorage  bit,
 HasPhotoInWorkStorage  bit,
 HasPhotoInMaterialStorage bit,
 HasHotelPhotoInReadyStorage  bit,
 HasHotelPhotoInWorkStorage  bit,
 HasHotelPhotoInMaterialStorage bit,
 HasReporterData  bit,
 HasMovieInReadyStorage  bit,
 HasMovieInWorkStorage  bit,
 HasMovieInMaterialStorage bit
};

Aşağıdaki hataları alıyorum:

Msg 102, Level 15, State 1, Line 2
Incorrect syntax near '('.
Msg 102, Level 15, State 1, Line 9
Incorrect syntax near '('.
Msg 102, Level 15, State 1, Line 15
Incorrect syntax near '('.
Msg 102, Level 15, State 1, Line 22
Incorrect syntax near '('.
Msg 102, Level 15, State 1, Line 29
Incorrect syntax near '{'.

CEVAP
26 Mart 2010, Cuma


Parantez kaldırmak gerekir

ALTER TABLE Countries
ADD  
HasPhotoInReadyStorage  bit,
 HasPhotoInWorkStorage  bit,
 HasPhotoInMaterialStorage bit,
 HasText  bit;

Bunu Paylaş:
  • Google+
  • E-Posta
Etiketler:

YORUMLAR

SPONSOR VİDEO

Rastgele Yazarlar

  • 365multimedia

    365multimedi

    26 ŞUBAT 2009
  • buttheadgsxr1000

    buttheadgsxr

    24 Ocak 2008
  • EminemVEVO

    EminemVEVO

    12 Mayıs 2009