Results 1 to 3 of 3
  1. #1
    Join Date
    Jul 2004
    Posts
    3

    Unhappy Unanswered: Lost some space (hardisk) when Execute Query

    Dear All,

    Got some problem...
    how come i lost some space (hardisk) when
    execute query...
    (the query is listed below)

    I want to know is it create some virtual tables or view when we execute query ???
    N where's the location in our hardisk ??

    thx


    Listed Query
    ---------------------
    SELECT Absen.BranchID, Bran.BranchName, Bran.BranchNote, Absen.DepartmentID,
    Absen.SubDepartmentID, Dis.AfdelingID, Dis.WilayahID,
    Dis.KemandoranCivilID, TekCiv.KemandoranCivilName, Absen.DateAbsensi as TglAbsensi,
    Absen.AbsensiID, Absen.KaryawanID, Data.JabatanID1, Jab.JabatanName,
    Data.GolonganID
    FROM AMBranchMaster Bran RIGHT OUTER JOIN
    HRDataKaryawan Data LEFT OUTER JOIN
    HRDistribusiKaryawan Dis LEFT OUTER JOIN
    TEKMasterKemandoranCivil TekCiv ON Dis.KemandoranCivilID = TekCiv.KemandoranCivilID ON
    Data.KaryawanID = Dis.KaryawanID RIGHT OUTER JOIN
    HRAbsensiKaryawan Absen ON Data.KaryawanID = Absen.KaryawanID ON
    Bran.BranchID = Absen.BranchID LEFT OUTER JOIN
    HRMasterJabatan Jab ON Data.JabatanID1 = Jab.JabatanID
    Union
    SELECT Absen.BranchID, Bran.BranchName, Bran.BranchNote, Dis.DepartmentID,
    Absen.SubDepartmentID, Dis.AfdelingID, Dis.WilayahID,
    Dis.KemandoranCivilID, TekCiv.KemandoranCivilName, Absen.TglAbsensi as TglAbsensi,
    Absen.AbsensiID, Absen.KaryawanID, Data.JabatanID1, Jab.JabatanName,
    Data.GolonganID
    FROM AMBranchMaster Bran RIGHT OUTER JOIN
    HRDataKaryawan Data LEFT OUTER JOIN
    HRDistribusiKaryawan Dis LEFT OUTER JOIN
    TEKMasterKemandoranCivil TekCiv ON Dis.KemandoranCivilID = TekCiv.KemandoranCivilID ON
    Data.KaryawanID = Dis.KaryawanID RIGHT OUTER JOIN
    ADMAbsensiKaryawan Absen ON Data.KaryawanID = Absen.KaryawanID ON
    Bran.BranchID = Absen.BranchID LEFT OUTER JOIN
    HRMasterJabatan Jab ON Data.JabatanID1 = Jab.JabatanID
    UNION
    SELECT Absen.BranchID, Bran.BranchName, Bran.BranchNote, Dis.DepartmentID,
    Absen.SubDepartmentID, Dis.AfdelingID, Dis.WilayahID,
    Dis.KemandoranCivilID, TekCiv.KemandoranCivilName, Absen.TglAbsensi as TglAbsensi,
    Absen.AbsensiID, Absen.KaryawanID, Data.JabatanID1, Jab.JabatanName,
    Data.GolonganID
    FROM AMBranchMaster Bran RIGHT OUTER JOIN
    HRDataKaryawan Data LEFT OUTER JOIN
    HRDistribusiKaryawan Dis LEFT OUTER JOIN
    TEKMasterKemandoranCivil TekCiv ON Dis.KemandoranCivilID = TekCiv.KemandoranCivilID ON
    Data.KaryawanID = Dis.KaryawanID RIGHT OUTER JOIN
    ADMAbsensiBulananSite Absen ON Data.KaryawanID = Absen.KaryawanID ON
    Bran.BranchID = Absen.BranchID LEFT OUTER JOIN
    HRMasterJabatan Jab ON Data.JabatanID1 = Jab.JabatanID
    Union
    SELECT Absen.BranchID, Bran.BranchName, Bran.BranchNote, Dis.DepartmentID,
    Absen.SubDepartmentID, Dis.AfdelingID, Dis.WilayahID,
    Dis.KemandoranCivilID, TekCiv.KemandoranCivilName, Absen.DateAbsensi as TglAbsensi,
    Absen.AbsensiID, Absen.KaryawanID, Data.JabatanID1, Jab.JabatanName,
    Data.GolonganID
    FROM AMBranchMaster Bran RIGHT OUTER JOIN
    HRDataKaryawan Data LEFT OUTER JOIN
    HRDistribusiKaryawan Dis LEFT OUTER JOIN
    TEKMasterKemandoranCivil TekCiv ON Dis.KemandoranCivilID = TekCiv.KemandoranCivilID ON
    Data.KaryawanID = Dis.KaryawanID RIGHT OUTER JOIN
    HRAbsensiKaryawanNonStaf Absen ON Data.KaryawanID = Absen.KaryawanID ON
    Bran.BranchID = Absen.BranchID LEFT OUTER JOIN
    HRMasterJabatan Jab ON Data.JabatanID1 = Jab.JabatanID
    UNION
    SELECT Absen.BranchID, Bran.BranchName, Bran.BranchNote, Dis.DepartmentID,
    Absen.SubDepartmentID, Dis.AfdelingID, Dis.WilayahID,
    Dis.KemandoranCivilID, TekCiv.KemandoranCivilName, Absen.DateAbsensi as TglAbsensi,
    Absen.AbsensiID, Absen.KaryawanID, Data.JabatanID1, Jab.JabatanName,
    Data.GolonganID
    FROM AMBranchMaster Bran RIGHT OUTER JOIN
    HRDataKaryawan Data LEFT OUTER JOIN
    HRDistribusiKaryawan Dis LEFT OUTER JOIN
    TEKMasterKemandoranCivil TekCiv ON Dis.KemandoranCivilID = TekCiv.KemandoranCivilID ON
    Data.KaryawanID = Dis.KaryawanID RIGHT OUTER JOIN
    HRAbsensiKaryawanStaf Absen ON Data.KaryawanID = Absen.KaryawanID ON
    Bran.BranchID = Absen.BranchID LEFT OUTER JOIN
    HRMasterJabatan Jab ON Data.JabatanID1 = Jab.JabatanID
    UNION
    SELECT Absen.BranchID, Bran.BranchName, Bran.BranchNote, Dis.DepartmentID,
    Absen.SubDepartmentID, Dis.AfdelingID, Dis.WilayahID,
    Dis.KemandoranCivilID, TekCiv.KemandoranCivilName, Absen.TglAbsensi as TglAbsensi,
    Absen.AbsensiID, Absen.KaryawanID, Data.JabatanID1, Jab.JabatanName,
    Data.GolonganID
    FROM AMBranchMaster Bran RIGHT OUTER JOIN
    HRDataKaryawan Data LEFT OUTER JOIN
    HRDistribusiKaryawan Dis LEFT OUTER JOIN
    TEKMasterKemandoranCivil TekCiv ON Dis.KemandoranCivilID = TekCiv.KemandoranCivilID ON
    Data.KaryawanID = Dis.KaryawanID RIGHT OUTER JOIN
    LCAbsensiBulananSite Absen ON Data.KaryawanID = Absen.KaryawanID ON
    Bran.BranchID = Absen.BranchID LEFT OUTER JOIN
    HRMasterJabatan Jab ON Data.JabatanID1 = Jab.JabatanID
    UNION
    SELECT Absen.BranchID, Bran.BranchName, Bran.BranchNote, Dis.DepartmentID,
    Absen.SubDepartmentID, Dis.AfdelingID, Dis.WilayahID,
    Dis.KemandoranCivilID, TekCiv.KemandoranCivilName, Absen.TglAbsensi as TglAbsensi,
    Absen.AbsensiID, Absen.KaryawanID, Data.JabatanID1, Jab.JabatanName,
    Data.GolonganID
    FROM AMBranchMaster Bran RIGHT OUTER JOIN
    HRDataKaryawan Data LEFT OUTER JOIN
    HRDistribusiKaryawan Dis LEFT OUTER JOIN
    TEKMasterKemandoranCivil TekCiv ON Dis.KemandoranCivilID = TekCiv.KemandoranCivilID ON
    Data.KaryawanID = Dis.KaryawanID RIGHT OUTER JOIN
    LCAbsensiIndirect Absen ON Data.KaryawanID = Absen.KaryawanID ON
    Bran.BranchID = Absen.BranchID LEFT OUTER JOIN
    HRMasterJabatan Jab ON Data.JabatanID1 = Jab.JabatanID
    UNION
    ...................

    ----------------

  2. #2
    Join Date
    Jan 2004
    Location
    In a large office with bad lighting
    Posts
    1,040
    You don't say how much space was lost. Are the databases set to auto-grow? If so, the generation of the result set of your query may have caused tempdb or your database to grow in order to accumulate the infomation prior to presenting it to you.

  3. #3
    Join Date
    Jul 2003
    Location
    San Antonio, TX
    Posts
    3,662
    You need to specify the error(-s) you're getting and post them here...Looks like either Access or View Builder wizard were used...That's the kind of mess those "tools" create...Seemingly an easy task to create any query, while the taste of the outcome may be very bitter...
    "The data in a record depends on the Key to the record, the Whole Key, and
    nothing but the Key, so help me Codd."

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •