If the RO.FST does not exist in the working draft folder, then grab it out of the RO folder
This commit is contained in:
parent
3a861fb555
commit
a319e2d487
@ -73,12 +73,14 @@ namespace DataLoader
|
|||||||
// now see if the same ro.fst has been migrated. To determine this check if a record
|
// now see if the same ro.fst has been migrated. To determine this check if a record
|
||||||
// exists for the rodb and with the same dts as the file.
|
// exists for the rodb and with the same dts as the file.
|
||||||
FileInfo fi = new FileInfo(fstPath + @"\ro.fst");
|
FileInfo fi = new FileInfo(fstPath + @"\ro.fst");
|
||||||
|
if (!fi.Exists)
|
||||||
|
fi = new FileInfo(roDbpath + @"\ro.fst");
|
||||||
|
|
||||||
ROFst rofst = ROFst.GetByRODbID_DTS(rodb.RODbID, fi.LastWriteTimeUtc);
|
ROFst rofst = ROFst.GetByRODbID_DTS(rodb.RODbID, fi.LastWriteTimeUtc);
|
||||||
if (rofst == null)
|
if (rofst == null) // if not already in our database, then add it.
|
||||||
{
|
{
|
||||||
// Next read in the rofst & make the rofst record.
|
// Next read in the rofst & make the rofst record.
|
||||||
FileStream fsIn = new FileStream(fstPath + @"\ro.fst", FileMode.Open, FileAccess.Read, FileShare.Read);
|
FileStream fsIn = new FileStream(fi.FullName, FileMode.Open, FileAccess.Read, FileShare.Read);
|
||||||
// Create an instance of StreamReader that can read characters from the FileStream.
|
// Create an instance of StreamReader that can read characters from the FileStream.
|
||||||
BinaryReader r = new BinaryReader(fsIn);
|
BinaryReader r = new BinaryReader(fsIn);
|
||||||
byte[] ab = r.ReadBytes((int)fsIn.Length);
|
byte[] ab = r.ReadBytes((int)fsIn.Length);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user