FAQ Database Discussion Community


Android sometimes my secondary storage.exists() returns true even if I unmount it

android,android-intent,storage,android-sdcard
I tried to detect secondary external storage(SD card) unmounted using broadcast receiver, and if so start running a thread and finish it until SD card is mounted. It works fine occasionally. however, when I try to know if directory exists or not, it sometimes returns true even if SD card...

How do large image services store their images efficiently?

image,compression,cloud,storage
While I understand most image files cannot be further compressed, how do large image services like imgur, flickr store their images? Do they simple dump everything into the file system then index it with db? Or do they compress multiple images into a more efficient package?

Write file: Data consistency in practice

caching,storage,consistency,acid
I am working on a multi-user file storage system, in the real world this system must face up to the event of system crash or power failure, so I'm researching for Consistency and Durability. Many of database systems supported ACID, and modern computer systems supported journaling file system. I have...

How to store php form data to a web server in a plain text file?

php,forms,server,storage
I have an assignment that calls for data entries from a php form to be stored in a plain text file on the same web server. I created the php form page and the plain text file but I am unsure how to connect the two. I've searched the internet...

Cookies in a mobile app

angularjs,cookies,storage
I am creating an Hybrid mobile app with Ionic Framework. I need to persist some data in the DOM, it is only Username and Email in one single view so I don't need too much storage. I am using cookies-ngCookies with Angular trough a service named $cookieStore, anyways, this service...

Best solution to cache objects and images on Android? [closed]

android,caching,storage
What is the preferred way of caching different objects (including images) on Android? My goal is to cache some data for quick access, and to keep them available for longer time (for days). Thanks!

How many disk space oracle synonym takes?

oracle,storage,space,disk,synonym
We've a problem at my company because everyone shares the development oracle database. Thus, if a developer wants to modify a procedure or package, for example, other's application will fail, until this first developer ends his work. So I thought it will be great if I could create a User...

Android: How to write a Bitmap to internal storage

java,android,bitmap,save,storage
I am making an app that gets images from a URL. I want to be able to store these images on the phone so that if the url is the same as before, the user won't have to wait for the image to load but instead the app will pull...

Representing NULL in binary

oracle,plsql,null,binary,storage
In PL/SQL DATE datatype stores fixed length values. They are stored in the binary format but displayed as character in the default format. Consider the following declaration: v_regdate DATE; Here v_regdate is not initialized , hence its value is NULL. Just wondering how NULL would be stored in the binary...

Programmatically switch USB between shared (disk mode) and mounted (charge only)

android,usb,storage
I have an old HTC Desire S connected to my PC with a USB cable, and am doing development work on both a PC program and an Android app. It is convenient for me to have the PC program write some test data to the Android device's SD card (needs...

Is there a way of stopping Azure Storage PutBlock method from timing out?

c#,azure,storage
I have a method to upload a file to Azure to my storage account. My Method is simple blob = new CloudBlockBlob(new Uri(Uri)); var ms = new MemoryStream(block.Data); blob.PutBlock(block.BlockId, ms, null) But sometimes my PutBlock is throwing an exception: Operation has timed out StackTrace at Microsoft.WindowsAzure.Storage.Core.Executor.Executor.ExecuteSync[T](RESTCommand`1 cmd, IRetryPolicy policy, OperationContext...

Loading image in onCreate doesn't fill adapter correctly

android,storage,android-adapter
My application is able to take pictures and to save and to show them in a list. They also can be deleted and the list is correctly updated. However, if I close the application and then launch it again, the list is no more correct. In detail: These are the...

Android: Is this method always available and present?

android,performance,storage,android-file
I want to make the most out root access to all folders. this order is correct and always available and present? File ffile = new File(Environment.getRootDirectory().getParent()); // return "/" // "/" out root access to all folders ...

Running Multiple Instances of megasync in Linux

linux,cloud,storage
I would like to know if there is a way to run multiple megasync, the cloud storage sync tool from MEGA.co.nz, because I have 2 different accounts, one personal and another for all my family. I'm running ArchLinux in my computer. Thank you!...

How to store messages between users in database?

mysql,database,storage,messages
I am building a small e-mail like messaging app for a project, where a user would send out a message to another with information like meeting times and such, and I'm wondering about how to store all the messages exchanged. My issues are: Should I store all messages between all...

Retrieving a value from a text file

android,text-files,storage
I am building an application that contains a quiz. As soon as the user finishes the quiz, an activity is shown to the user where it calculates his total score as a TextView. What I want to achieve here is storing that TextView value shown to the user at the...

Ideal number of files per folder for large sets of files

filesystems,repository,storage
I am currently in the process of designing a simple repository that uses the file system to store documents. There is the future potential for millions of files and the strategy that I want to use to map an ID to a location on disk is a means of hashing...

How to get total internal memory (including system memory)

android,storage,environment
This code return total internal memory size: public static String getTotalInternalMemorySize() { File path = Environment.getDataDirectory(); StatFs stat = new StatFs(path.getPath()); long blockSize = stat.getBlockSize(); long totalBlocks = stat.getBlockCount(); return formatSize(totalBlocks * blockSize); } But this size is without system used memory. For example, at the GALAXY NOTE 3 is...

How to use macbook storage space for linux kernel development from other linux machine?

osx,git,ubuntu,linux-kernel,storage
I have Macbook pro and HP Compaq mini(running ubuntu 14.04, used for testing custom kernel). Now what I need is, I want to have the whole linux source in macbook storage but need to work on that source from linux machine( HP Compaq in my case). So if something goes...

Java- Mapping multi-dimensional arrays to single

java,arrays,memory,storage,bitset
I am posting this in relation to another open question i have, however I thought that this deserved it's own question. Alternate question (for reference): Java Proxy Discovering Bot Basically, I need to store a very large amount of data and have it accessible very quickly. This would work ideally...

StorageItemAccessList like functionality in Android

android,windows,storage
For windows, we have StorageItemAccessList to get a token for a file that users opens,which helps us to access the same file in future using the same token and not care if the file was moved to other location. Do we have similar support in android? My requirement is that,...

Best storage option for temporary data

nosql,relational-database,storage
In the context of an application I am developing I need to store quite a good amount of data for limited amount of time - think of the scenario in terms of object buckets - for a certain limited amount of time objects are in some buckets then they move...

Can't read file in subdirectory on android

android,file,storage
I'm trying to read a file from a folder on my Galaxy S4. When I place the file in the root directory, I can access it without problems: File f = new File(Environment.getExternalStorageDirectory().getAbsolutePath(), "MyFile"); But I want to put my file in a subdirectory. When I make a folder 'A',...

The storage system passwords

python,encryption,passwords,storage
At work we are doing monitoring system servers. We have passwords that give access to the servers. Kept it all should in the database. We will be held on the basis of encrypted passwords, and must connect to servers using the decrypted passwords. The problem - where to store the...

Intersystems Caché custom storage of persistent object

storage,persistent,intersystems-cache,intersystems
I have data in global in this format: ^kza("mltab","TAB","Dta",1,1) = 3341 ^kza("mltab","TAB","Dta",1,2) = "First Name" ^kza("mltab","TAB","Dta",1,3) = "type1" ^kza("mltab","TAB","Dta",1,4) = 7400.11 ^kza("mltab","TAB","Dta",2,1) = 3614 ^kza("mltab","TAB","Dta",2,2) = "Second Name" ^kza("mltab","TAB","Dta",2,3) = "type2" ^kza("mltab","TAB","Dta",2,4) = 7600.11 My object class looks like this: Class Kza.Employees Extends %Persistent [ StorageStrategy = EmpStorage ] {...

C# azure download all files

c#,azure,download,storage,blobs
I want to download all Files from the Container "$logs", but a StorageException is thrown. CloudStorageAccount storageAccount = CloudStorageAccount.Parse("DefaultEndpointsProtocol=https;AccountName=" + accName + ";AccountKey=" + accKey); CloudBlobClient blobClient = storageAccount.CreateCloudBlobClient(); CloudBlobContainer container = blobClient.GetContainerReference("$logs"); IEnumerable<IListBlobItem> ListBlobs = container.ListBlobs(string.Empty, true); foreach (var item in ListBlobs) { CloudBlockBlob blockBlob =...

AngularJS - store page data

json,angularjs,storage
I would like to store my datas with local storage or cookie. The data source is a json and this json has a data limitation (10 data per page). So I implemented a "show more" function, which is loads the other jsons when I click a button. My problem is...

Install android sdk in eclipse without downloading full os

android,eclipse,sdk,install,storage
I would like to install the SDK for several android platforms on my chromebook using Ubuntu with crouton when I get it. The problem is that the chromebook I might get only has 16gb minus the OS. Installing the android SDK to eclipse also seems to install the whole emulator...

Context, storing internal memory and reading from it

android,storage,internal,android-context
Hello I have a problem with the context in the line productLookup(productId, Contexto), I can't get it right. What I'm trying to do is when I get the data from the DB via web, with the objects I also want to pass the ID of the objects to the productLookup...

Storing a dictionary in swift in permanent storage

swift,storage,permanent
this code here throws an error when I run the app var dic :[NSObject: AnyObject] = ["name":"steph" , "status": "unemployed"] NSUserDefaults.standardUserDefaults().setObject(array, forKey: "diction") var retrievedDict = NSUserDefaults.standardUserDefaults().objectForKey("diction")! as NSDictionary let g = dic["name"] println(g) what's wrong with this?...

Storing bitmap into sql

vb.net,image,storage
I'm coding an app for printing bills. I have a form within I load data. I want to automate printing, so in that order i save a bmp image of my filled form and then store into a mdf database for late print each row/cell (images in this case). But...

Save order data to local database

c#,sql,winforms,schema,storage
I am using C# to create a Windows form application. How do I create a local database table to save the data described below? Currently my data table consists of the columns of "inv_Id", "Item_Id" and "quantity". I know I need to create the columns to store each of the...

Get folder from windows service(system.io) to Windows store App (Windows.Storage)

.net,vb.net,windows-store-apps,windows-8.1,storage
I currently have an application which needs to retrieve images from a server and copy them locally on a tablet. The problem is that I don't have access to the server from my application. This is why I use a Windows Service to get data from my database or in...

A Simple Image Gallery from scratch

javascript,html,image,storage
I wanna make a next-prev type webcomic image gallery like that of xkcd or smbc but I'm having a bit of a rough start. I've been asking the wrong people and searching for the wrong things. Obviously, this has even been asked here before but I want to make it...

How to get storage capacity of mac programatically?

objective-c,xcode,osx,cocoa,storage
I am having a mac app. As shown in the screenshot, I want to get this programmatically in my cocoa application for Mac OS X. I want to get the total capacity, available space and free space. Can anyone help me on this? Thanks......

No space left on device [closed]

ruby-on-rails,apache,ubuntu,amazon-web-services,storage
I can no longer generate new columns in my database. My stack is below. I am new to managing my own server and am unfamiliar with Apache, Ubuntu and AWS. Currently I am receiving an error saying that I have no space left. It looks like my folder /dev/xvda1 is...

Use parcelable to store item as sharedpreferences?

java,android,storage,serializable
I have a couple objects, Location, in my app stored in an ArrayList and use parcelable to move these between activities. The code for the object looks like this: public class Location implements Parcelable{ private double latitude, longitude; private int sensors = 1; private boolean day; private int cloudiness; /*...

Detecting internet and saving to internal storage in that case in Android using PHP and MySQL

php,android,mysql,storage,internal
I'm making an app in Android Studio that connects to a database and sends a report to it with a POST request with PHP. What I want to achieve is that when the device doesn't have internet I want the report to save to an internal file and when it...

session Storage not working in device

ios,session,storage,ionic
I'm keeping in session one json array, the evidence that I do in the browser function without problem but when I try to test them on devices (iOS or Android) does not hold anything, I am using AngularJS + ionic. With this function I keep everything: .factory('sessionService',['$http',function($http){ return { set:function(key,value){...

What storage options are available for using PlayReady on Azure Media Services?

storage,azure-media-services
My company runs a web service for film and tv production/distribution companies, and we already have a large catalog of video online. We are interested in using PlayReady with Azure Media Services and the JW Player to better protect the content we stream to our customers. Every guide I can...

Storing images in MSSQL vs Disk

sql-server,image,filesystems,storage
I am developing an inhouse application in C#.NET, based on an MSSQL database. Users can upload images linked to a specific entity. These images have usually around 4 to 5 MB and cannot be compressed for storage. Right now these images are stored in the filesystem where the application is....

Kubernetes Storage on bare-metal/private cloud

storage,persistent,pod,kubernetes
I'm just starting with Kubernetes on 2 node (master-minion) setup on 2 private cloud servers. I've installed it, did basic config and got it running some simple pods/services from the master to the minion. My question is: How can I use persistent storage with the pods when not using Google...

how to remove data from a object using chrome storage?

javascript,google-chrome-extension,storage,google-chrome-storage
i have an object stored inside chrome storage that looks like this: { "planA": { 123: {key: 'some key'} 124: {key: 'some other key'} }, "planB": { 223: {key: 'some key'} 234: {key: 'some other key'} } } i want to do something like chrome.storage.sync.remove([{"planA": "123"}]); but that seems not...

What would be the best idea for this kind of storage in database?

mysql,database,storage
I'm currently looking into the best way of saving some data in my database for each user. Lets say each user can save recipes on their account, then what would be the best way of doing this? I thought of storing a JSON string in a column, but I read...

Use case HBase on EMR

hadoop,amazon-web-services,hbase,storage,emr
I read the documentation on AWS, but a point is still unclear. Is S3 the primary storage of EMR cluster? or does the data are in EC2 and S3 is just a copy? In the doc : "HBase on Amazon EMR provides the ability to back up your HBase data...

Storing Mutable Dictionary in iOS

ios,dictionary,storage
I am creating a dictionary in my iOS app that will hold thousands of Strings. The app writes and reads from it very often (100 times whenever the user refreshes the feed), so speed is important. Also, it needs to be saved beyond sessions. I have tried NSUserDefaults, but it...

Where to save public data when External Storage status is “removed”?

android,storage
I have a device with a "removed" external storage. Is it possible to save data to another public location (where other apps can access)?

Creating a storage class, sorted and limited by weight

java,arraylist,storage
Sorry for asking this, but i could really use a new PoV. Been sitting on it for days and can't wrap my head around it. Basically, i have a Class Screw, whose object has attributes like length, material etc. It also saves the amount of screws and the weight this...

Should I use Blob storage or Azure VM storage for files?

transactions,asp.net-mvc-5,storage,windows-azure-storage,azure-virtual-machine
I am coding a MVC 5 internet application that is being stored on an Azure VM. In this internet application, user can upload files such as images and videos that can be accessed by the public via a url. My question is this: Should I store this uploaded data in...

Not enough storage is available to complete this operation - matlab

matlab,storage,ram
I am using Matlab 2014a under Windows7. I am running a loop that reads very big xlsx files (~40MB each). After I am done with a file I use 'clear' in order to free the memory taken by reading the file. The thing is that every once in a while...

What is the source of a wrong pointer value?

c,storage
EDIT: I know the second example is wrong and i know how to make it right, i want to know where does the wrong values came from and where do they point to when there is nothing? how does a became the value of 2686744 Sry i dont know what...

HTML,css,js issue when loading html from sdcard to webview in android?

javascript,android,html,css,storage
i am loading html file from sdcard to webview but when i load html from sdcard to webview it will not load properly css and images and video is not loading in webview. Work With 4.4 kitkat and chrome version Not Work With below 4.4 kitkat version I have tried...

Android: How to get images from camera without storing a file?

android,camera,storage,ram
I'm using the system's activity to get an image from camera. Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); startActivityForResult(intent, REQUEST); When the user accept the photo I use this callback @Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { super.onActivityResult(requestCode, resultCode, data); if (requestCode == REQUEST && resultCode == RESULT_OK) {...

Is the storage location “storage” for all Android devices and versions fixed?

android,storage,android-sdcard
I want to know : /storage/sdcard0/ and /storage/sdcard1/ directory location for all android devices and versions available and unchanged? Namely, can i use this /storage/... in my code? I want to be sure this is the root of all versions are available or not. ! for example : File root...

How to save select option in localStorage with jQuery?

jquery,storage,selection,local
I am trying to save selected option in localStorage in HTML, so if you refresh page, the selection stays selected. I have try this: HTML: <select id="edit"> <option>1</option> <option>2</option> <option>3</option> </select> jQuery: $(function() { $('#edit').change(function() { localStorage.setItem('todoData', this.innerHTML); }); if(localStorage.getItem('todoData')){ localStorage.getItem('todoData'); } }); But this seems not to work, any...

Send alert for 80% threshold comparing two values from Disk partition

linux,unix,ubuntu,storage,diskspace
Need send a alert comparing two values of disk space for all partition It should check for SIZE and USED values and compare values makesure not more than 80% Filesystem Size Used Avail Mounted /dev/sda1 9,9G 3,3G 6,1G / none 17G 213k 17G /dev none 17G 0 17G /dev/shm none...

Is it better to use `null` or `-1` to indicate “infinite” in integer columns of the database

php,mysql,database,doctrine2,storage
I often have fields in my database which store "a number or infinite". Examples could be maxFileSize, maxUsers, etc. It shall be possible to set a maximum value or just don't restrict it at all. I currently sometimes use null to indicate "infinite / no restriction" and sometimes use -1....

Cordova/Javascript localStorage.setItem Only on first boot

javascript,json,cordova,storage
I am wondering if its possible to only call localStorage.setItem on the first boot. I just want to set up a json file for later use and I don't want the saved information to get wiped again because of the localStorage.setItem each time you restart the app. Whats the best...